<template>
  <div id="index">
    <Transfer
      :select="select"
      :waitForList="waitForList"
      :columns="columns"
      :keys="keys"
      @onSubmit="onSubmit"
      @cancel="cancel"
    />
  </div>
</template>

<script>
import Transfer from "@/components/Transfer";
export default {
  components: {
    Transfer,
  },
  data() {
    return {
      keys: "managerNo",
      select: [], // 选中商品
      waitForList: [
        // 待选商品
        { name: "aa", managerNo: 11 },
        { name: "bb", managerNo: 12 },
        { name: "cc", managerNo: 13 },
      ],
      columns: [
        {
          prop: "name",
          label: "名称",
          width: 100,
        },
        {
          prop: "managerNo",
          label: "数值",
        },
      ],
    };
  },
  created() {},
  methods: {
    onSubmit(list) {
      console.log(list);
    },
    cancel() {
      console.log(this.waitForList);
    },
  },
};
</script>

<style scoped lang="less">
#index {
  padding: 0 100px;
}
</style>
